cmake_minimum_required(VERSION 2.8)
PROJECT(qtcube)
enable_language(ASM)
set_property ( SOURCE libkubs.s PROPERTY LANGUAGE ASM )
 
find_package(Qt4 4.4.3 COMPONENTS QtCore QtOpenGL QtGui QtXml REQUIRED )
#SET(qtcube_SOURCES libkubs64.s libkubs.s trackball.cpp mainwindow.cpp main.cpp)
SET(qtcube_SOURCES libkubs.s kubs.cpp pozicijas.cpp ArcBall.cpp mainwindow.cpp main.cpp)
SET(qtcube_HEADERS cubegrammar.h kubs.h pozicijas.h ArcBall.h  mainwindow.h)
SET(qtcube_FORMS mainwindow.ui)
QT4_WRAP_CPP(qtcube_HEADERS_MOC ${qtcube_HEADERS})
QT4_WRAP_UI(qtcube_FORMS_HEADERS ${qtcube_FORMS})
SET(QT_USE_QTOPENGL TRUE)
SET(QT_USE_QTXML TRUE)
INCLUDE(${QT_USE_FILE})
ADD_DEFINITIONS(${QT_DEFINITIONS})
include_directories (.)
SET(Boost_ADDITIONAL_VERSIONS 1.44.0,1.45.0,1.46.0,1.47.0,1.48.0)
SET(BOOST_INCLUDEDIR c:/test/boost_trunk)
find_package(OpenGL)
find_package( Boost 1.41 )
  if(Boost_FOUND AND QT4_FOUND AND OPENGL_FOUND )
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR})
     include_directories(${Boost_INCLUDE_DIRS})
     
  
ADD_EXECUTABLE(qtcube ${qtcube_SOURCES}
    ${qtcube_HEADERS_MOC}
    ${qtcube_FORMS_HEADERS})
target_link_libraries(qtcube ${QT_LIBRARIES})
target_link_libraries(qtcube ${OPENGL_LIBRARIES})
endif()